#pragma once
#include"ser.h"

class Login_info
{
	public:
		Login_info();
		Login_info(bufferevent *bfev,string &act,string &name);
		Login_info(const Login_info&);
		Login_info&operator=(const Login_info&);
		
		const bufferevent *get_bfev();
		const string& get_act();
		const string& get_name();
	private:
		bufferevent *bfev;
		string act;
		string name;
};

struct Node
{
	Login_info lf;
	Node *next;
};


class Login_list
{
	public:
		Login_list();
		void insert(bufferevent *bfev,string &act, string &name);
		void erase(bufferevent* bfev);
		const string *get_act(const bufferevent* bfev); 
		const string *get_name(const bufferevent* bfev); 
		void sd_meg(const string &);
		~Login_list();
	private:
		Node *head;
		Node *end;
		int size;
};